<?php include_once '../library/TimeZoneSelect.php'; ?>
<?php if(isset ($this->info['locale'])){?>
<script type="text/javascript">
    var locale = '<?php echo $this->info['locale'] ?>';
    $( document ).ready( function() {
        $( "#tz [value='" + locale + "']" ).attr( "selected", "selected" );
    } );
</script>
<?php } ?>
<div>
    
    <h5><?php echo $this->trans->_($this->info['title']) ?></h5>
    <form id="infoForm" rel="globalModule.checkAdminUserInfo" onsubmit="return false;" method="post" action="" >
        <table id="modalTableInfo" class="info-table" >
            <?php foreach ($this->info['fields'] as $val) {
            ?>
                <tr>
                    <td><?php echo $this->trans->_($val['name']); ?></td>
                    <td>
                    <?php echo GetSnippets::getField($val) ?>
                </td>
            </tr>
            <?php } ?>
            <tr>
            <td><?php echo $this->trans->_( 'settings_gen_tz' );?></td>
            <td>
                <select name="tz" id="tz" class="inp-txt" style="width:235px">
                    <option value='NULL'><?php echo $this->trans->_( 'time_zone_select' );?></option>
                    <?php
                    if( !empty( $select[$this->lang] ) ) {
                        echo $select[$this->lang];
                    } else {
                        echo  $select['en'];
                    }
                    ?></select></td>
        </tr>
            </table>
        <?php $event = ($this->event) ? $this->event : 'insert'; ?>
                <input type="hidden" name="event" value="<?php echo $event; ?>"/>
        <?php if (isset($this->id)) {
 ?>
                    <input type="hidden" name="id" value="<?php echo $this->id ?>"/>
<?php } ?>
    </form>
</div>